﻿function handle(){

        var nm = document.getElementsByName('login')[0],
            pswrd = document.getElementsByName('password')[0],
            submit = document.getElementsByName('login_submit')[0];

            if (nm.value !== '' && pswrd.value !== '') {

                submit.disabled = '';
                submit.style.background = "#D14335";
                submit.style.borderColor = "#D14335";
                }
        else  {

           submit.disabled = 'disabled';
           submit.style.background = "#DDD3C9";
           submit.style.borderColor = "#DDD3C9";
           }

}